SUPPORT / SAMPLES & SAS NOTES
 

Support

Problem Note 45620: The value of the SYSERR macro variable might be incorrect when you execute the IMPORT procedure in SAS batch mode

DetailsAboutRate It

The SYSERR automatic macro variable might not be set to a nonzero value when the IMPORT procedure fails. The problem occurs under the following circumstances:

  • If you are running SAS in batch mode rather than interactive mode
  • If the error in the IMPORT procedure occurs when reading a nonexistent sheet

The following is an example:
    proc import datafile='c:\sastest\myexcel.xls' 
     out=sastest  
     dbms=xls;
     sheet='barney';
run;

Requested Sheet Name not found on Excel -> c:\sastest\myexcel.xls
Requested Input File Is Invalid
ERROR: Import unsuccessful.  See SAS Log for details.
NOTE: PROCEDURE IMPORT used (Total process time):
      real time           0.00 seconds
      cpu time            0.00 seconds


    %put &syserr;
0

In this example, the correct value of SYSERR is 1012.

A fix for this issue is planned for a future release.



Operating System and Release Information

Product FamilyProductSystemProduct ReleaseSAS Release
ReportedFixed*ReportedFixed*
SAS SystemSAS/ACCESS Interface to PC FilesMicrosoft® Windows® for x649.39.3_M29.3 TS1M09.3 TS1M2
Microsoft Windows Server 2003 Datacenter Edition9.39.3_M29.3 TS1M09.3 TS1M2
Microsoft Windows Server 2003 Enterprise Edition9.39.3_M29.3 TS1M09.3 TS1M2
Microsoft Windows Server 2003 Standard Edition9.39.3_M29.3 TS1M09.3 TS1M2
Microsoft Windows Server 2003 for x649.39.3_M29.3 TS1M09.3 TS1M2
Microsoft Windows Server 20089.39.3_M29.3 TS1M09.3 TS1M2
Microsoft Windows Server 2008 for x649.39.3_M29.3 TS1M09.3 TS1M2
Microsoft Windows XP Professional9.39.3_M29.3 TS1M09.3 TS1M2
Windows 7 Enterprise 32 bit9.39.3_M29.3 TS1M09.3 TS1M2
Windows 7 Enterprise x649.39.3_M29.3 TS1M09.3 TS1M2
Windows 7 Home Premium 32 bit9.39.3_M29.3 TS1M09.3 TS1M2
Windows 7 Home Premium x649.39.3_M29.3 TS1M09.3 TS1M2
Windows 7 Professional 32 bit9.39.3_M29.3 TS1M09.3 TS1M2
Windows 7 Professional x649.39.3_M29.3 TS1M09.3 TS1M2
Windows 7 Ultimate 32 bit9.39.3_M29.3 TS1M09.3 TS1M2
Windows 7 Ultimate x649.39.3_M29.3 TS1M09.3 TS1M2
Windows Vista9.39.3_M29.3 TS1M09.3 TS1M2
Windows Vista for x649.39.3_M29.3 TS1M09.3 TS1M2
* For software releases that are not yet generally available, the Fixed Release is the software release in which the problem is planned to be fixed.